//
//  TACP_TestModel.m
//  AutoCreatePropertyDemo
//
// Created by userName on 2017/11/30.
//  Copyright © 2017年 __MyCompanyName__ All rights reserved.
//

#import "TACP_TestModel.h"

@implementation TACP_TestModel

- (instancetype)initWithDictionary:(NSDictionary *)dict {
    self = [super initWithDictionary:dict];
    if (self) {
        self.id = int_value_from_num(not_null_obj_from_dict_with_key(dict, @"id"));

        self.arrayStr = [self arrayFromDatasource:not_null_obj_from_dict_with_key(dict, @"arrayStr") subClassName:@"NSString"];

        self.arrayNum = [self arrayFromDatasource:not_null_obj_from_dict_with_key(dict, @"arrayNum") subClassName:@""];

        self.strArray = [self arrayFromDatasource:not_null_obj_from_dict_with_key(dict, @"strArray") subClassName:@"NSString"];

        self.arrayDict = [self arrayFromDatasource:not_null_obj_from_dict_with_key(dict, @"arrayDict") subClassName:@"TACP_ArrayDict"];

        self.intValue = int_value_from_num(not_null_obj_from_dict_with_key(dict, @"intValue"));

        self.desc = not_null_obj_from_dict_with_key(dict, @"desc");

        self.doubleValue = double_value_from_num(not_null_obj_from_dict_with_key(dict, @"doubleValue"));

        self.abc = int_value_from_num(not_null_obj_from_dict_with_key(dict, @"abc"));

        self.imageArray = [self arrayFromDatasource:not_null_obj_from_dict_with_key(dict, @"imageArray") subClassName:@"TACP_ImageArray"];

        self.douleAbc = double_value_from_num(not_null_obj_from_dict_with_key(dict, @"douleAbc"));

        self.bannerArray = [self arrayFromDatasource:not_null_obj_from_dict_with_key(dict, @"bannerArray") subClassName:@"NSString"];

    }
    return self;
}

//请不要动此方法，否则再次生成时无法添加正确的解析字符串
+ (NSString *)description {
    NSString *string = @"WyAgeyAgICAiY2xhc3NOYW1lIiA6ICJOU0ludGVnZXIiLCAgICAicHJvcGVydHlOYW1lIiA6ICJpZCIgIH0sICB7ICAgICJjbGFzc05hbWUiIDogIk5TQXJyYXkiLCAgICAicHJvcGVydHlOYW1lIiA6ICJhcnJheVN0ciIsICAgICJzdWJNb2RlbCIgOiB7ICAgICAgImNsYXNzT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bCIgICAgICB9ICAgIH0gIH0sICB7ICAgICJjbGFzc05hbWUiIDogIk5TSW50ZWdlciIsICAgICJwcm9wZXJ0eU5hbWUiIDogImludFZhbHVlIiAgfSwgIHsgICAgImNsYXNzTmFtZSIgOiAiTlNTdHJpbmciLCAgICAicHJvcGVydHlOYW1lIiA6ICJkZXNjIiAgfSwgIHsgICAgImNsYXNzTmFtZSIgOiAiZG91YmxlIiwgICAgInByb3BlcnR5TmFtZSIgOiAiZG91YmxlVmFsdWUiICB9LCAgeyAgICAiY2xhc3NOYW1lIiA6ICJOU0ludGVnZXIiLCAgICAicHJvcGVydHlOYW1lIiA6ICJhYmMiICB9LCAgeyAgICAiY2xhc3NOYW1lIiA6ICJOU0FycmF5IiwgICAgInByb3BlcnR5TmFtZSIgOiAiaW1hZ2VBcnJheSIsICAgICJzdWJNb2RlbCIgOiB7ICAgICAgImNsYXNzTmFtZSIgOiAiVEFDUF9JbWFnZUFycmF5IiwgICAgICAicHJvcGVydHlOYW1lIiA6ICJpbWFnZUFycmF5IiwgICAgICAic3VwZXJDbGFzc05hbWUiIDogIlRBQ1BfQmFzZU1vZGVsIiAgICB9ICB9LCAgeyAgICAiY2xhc3NOYW1lIiA6ICJkb3VibGUiLCAgICAicHJvcGVydHlOYW1lIiA6ICJkb3VsZUFiYyIgIH0sICB7ICAgICJjbGFzc05hbWUiIDogIk5TQXJyYXkiLCAgICAicHJvcGVydHlOYW1lIiA6ICJiYW5uZXJBcnJheSIsICAgICJzdWJNb2RlbCIgOiB7ICAgICAgImNsYXNzTmFtZSIgOiAiTlNTdHJpbmciLCAgICAgICJwcm9wZXJ0eU5hbWUiIDogImJhbm5lckFycmF5IiAgICB9ICB9XQ==";
    NSData *decodedData = [[NSData alloc] initWithBase64EncodedString:string options:0];
    NSString *decodedString = [[NSString alloc] initWithData:decodedData encoding:NSUTF8StringEncoding];
    return decodedString;
}


@end